package Pets;
//兔子属性：编号，名字，种类，性别，年龄，体重
public class Rabbit extends Pet{
//        @Override
//    public void setAge(double age) {
//        if (age > 1 || age <= 0) {
//            System.out.println("兔子的年龄只能在0~1岁之间！");
//            return;
//        } else {
//            super.setAge(age);
//            return;
//        }
//    }
    private float weight;

    public float getWeight() {
        return weight;
    }

    public void setWeight(float weight) {
        this.weight = weight;
    }
}
